package lambda;

/**
 * @ProjectName: sky-take-out
 * @Titile: testD
 * @Author: 霍静
 * @Description: TODO
 */
public class testD {
    public static void main(String[] args) {
        D d = new D() {
            @Override
            public int max(int a,int b) {
                return a>b?a:b;
            }
        };
        System.out.println(d.max(10, 20));

        D d1 = Math::max;
        int result = d1.max(30, 40);
        System.out.println(result);

    }
}
